package com.demo.pattern.single;

// 懒汉式，枚举
public class DemoTest8 {
    public static void main(String[] args) {
        Single8.INSTANCE.sayOk();
    }
}
enum Single8 {
    INSTANCE;
    public void sayOk() {
        System.out.println("sayOk");
    }
}